from Tkinter import *
import Tkinter
import tkMessageBox
import aim.vars as vars

class statusBox(Frame):

    def __init__(self, master=None):

        self.win = Toplevel(master)
        Frame.__init__(self,master)


        self.columnconfigure(0, weight=1)
        self.columnconfigure(2, weight=1)
        self.columnconfigure(3, weight=1)
        self.status = Label(self, text="Status")
        self.grid(padx=2, pady=2,sticky=N+S+E+W)
        self.USBstatus = StringVar()
        self.USBstatus.set("USB Disconnected")
        if vars.connectivity == None:
            vars.connectivity = StringVar()
            vars.connectivity.set("AIM Disconnected")


        self.USBLabel = Label(self, textvariable=self.USBstatus)
        self.AIMLabel = Label(self, textvariable=vars.connectivity)

        self.status.grid(row=0, column=2, sticky=N)
        self.AIMLabel.grid(row=1, column=0, sticky=W)
        self.USBLabel.grid(row=1, column=3, sticky=E)

    
if __name__ == "__main__":
    print "Not a main module"
    root = Tk()
    eu = statusBox(root)
    while(1):
        eu.update()
    
    


